package bat.ke.qq.com.tx.dao;

import bat.ke.qq.com.tx.bean.Account;
import org.apache.ibatis.annotations.*;

/**
 *
 *
 *
 *
 */

@Mapper
public interface AccountMapper {

    @Insert("insert into t_account(username,balance) values(#{username},#{balance})")
    void insert(Account account);

    @Update("update t_account set balance=#{balance} where username=#{username}")
    void update(@Param("username") String username, @Param("balance") int balance);

    @Select("select * from t_account where username=#{username}")
    Account getOne(String username);
}
